#ifndef _AUDIO_BOARD_DEFINITION_H_
#define _AUDIO_BOARD_DEFINITION_H_

#define SDCARD_OPEN_FILE_NUM_MAX  0
/* SD card related */
#define SD_CARD_INTR_GPIO           -1	
#define SD_CARD_INTR_SEL            -1	
#define SD_CARD_OPEN_FILE_NUM_MAX   0
#define ESP_SD_PIN_CMD              -1
#define ESP_SD_PIN_CLK              -1
#define ESP_SD_PIN_D0               -1
#define ESP_SD_PIN_D1               -1
#define ESP_SD_PIN_D2               -1
#define ESP_SD_PIN_D3               -1

/* LED indicators */
#define GPIO_LED_GREEN              -1
#define GPIO_LED_RED                -1
#define GPIO_LED_BLUE               -1

/* pwr io*/
#define GPIO_PERH_PWR               14

/* I2C gpios */
#define IIC_CLK                     32
#define IIC_DATA					33

/* PA */
#define GPIO_PA_EN                  -1
#define GPIO_SEL_PA_EN              -1
#define BOARD_PA_GAIN               10

/* Press button related */
#define  GPIO_REC                   GPIO_NUM_5
#define  GPIO_MODE                  GPIO_NUM_15
#define  GPIO_PLAY                  -1
									//   GPIO_NUM_4    //pwr
#define  GPIO_VOLUP                 GPIO_NUM_13    //vol
#define  GPIO_SET                   -1
#define  GPIO_VOLDWN				-1

// #define  TOUCH_SEL_REC				GPIO_SEL_5   
// #define  TOUCH_SEL_MODE				GPIO_SEL_15    //menu
// #define  TOUCH_SEL_PLAY				-1
// 									//GPIO_SEL_4
// #define  TOUCH_SEL_VOLUP			GPIO_SEL_13
// #define  TOUCH_SEL_VOLDWN			-1
// #define  TOUCH_SEL_SET              -1

/* I2S gpios */
#define IIS_SCLK                    27
#define IIS_LCLK                    25
#define IIS_DOUT                    26
#define IIS_DSIN                    35

#define AUXIN_DETECT_GPIO         -1
#define HEADPHONE_DETECT          -1

extern audio_hal_func_t AUDIO_CODEC_ES8388_DEFAULT_HANDLE;

#define AUDIO_CODEC_DEFAULT_CONFIG(){                   \
        .adc_input  = AUDIO_HAL_ADC_INPUT_LINE1,        \
        .dac_output = AUDIO_HAL_DAC_OUTPUT_ALL,         \
        .codec_mode = AUDIO_HAL_CODEC_MODE_BOTH,        \
        .i2s_iface = {                                  \
            .mode = AUDIO_HAL_MODE_SLAVE,               \
            .fmt = AUDIO_HAL_I2S_NORMAL,                \
            .samples = AUDIO_HAL_08K_SAMPLES,           \
            .bits = AUDIO_HAL_BIT_LENGTH_16BITS,        \
        },                                              \
};

#define INPUT_KEY_NUM     3

#define INPUT_KEY_DEFAULT_INFO() {                      \
     {                                                  \
        .type = PERIPH_ID_BUTTON,                       \
        .user_id = INPUT_KEY_USER_ID_REC,               \
        .act_id = GPIO_REC,                        \
    },                                                  \
    {                                                   \
        .type = PERIPH_ID_BUTTON,                       \
        .user_id = INPUT_KEY_USER_ID_MODE,              \
        .act_id = GPIO_MODE,                       \
    },                                                  \
    {                                                   \
        .type = PERIPH_ID_BUTTON,                        \
        .user_id = INPUT_KEY_USER_ID_VOLUP,             \
        .act_id =GPIO_VOLUP,                      \
    }                                                   \
}

#endif
